package com.Smart.smartscals.Adapter;

import java.util.ArrayList;

import com.Smart.smartscals.Fragment.BaseFragment;

import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentPagerAdapter;
import android.support.v4.app.FragmentStatePagerAdapter;
import android.support.v4.view.ViewPager;
import android.util.Log;
import android.view.View;
import android.view.ViewGroup;
import android.widget.BaseAdapter;

public class MainViewPagerAdapter extends FragmentStatePagerAdapter {

	private ArrayList<BaseFragment> arrayListBaseFragments;
	private FragmentManager fm;

	public MainViewPagerAdapter(FragmentManager fm,
			ArrayList<BaseFragment> arrayListBaseFragments) {
		super(fm);
		this.fm = fm;
		Log.d("msg", "---->Fragmen:MainViewPagerAdapter");
		this.arrayListBaseFragments = arrayListBaseFragments;
		// TODO Auto-generated constructor stub
	}



	@Override
	public Fragment getItem(int arg0) {
		Log.d("msg", "---->Fragmen:getItem");
		return arrayListBaseFragments.get(arg0);
	}

	@Override
	public int getCount() {
		Log.d("msg", "---->Fragmen:getCount");
		// TODO Auto-generated method stub
		return arrayListBaseFragments.size();
	}

}
